import { Vector3 } from "@minecraft/server";
import { Vector3Utils } from "@sapi-game/utils";

export interface PKMapData {
    name: string;
    spawnPos: Vector3;
    structureName: string;
    volume: Vector3;
    offset: Vector3;
}

const PKPitMap: PKMapData = {
    name: "矿洞",
    structureName: "你的跑酷我来造:矿洞",
    spawnPos: { x: 9, y: 10, z: 9 },
    volume: Vector3Utils.subtract(
        { x: 784, y: -26, z: 512 },
        { x: 767, y: -57, z: 495 }
    ),
    offset: { x: 0, y: 1, z: 0 },
};

const PKNetherMap: PKMapData = {
    name: "地狱",
    structureName: "你的跑酷我来造:地狱",
    spawnPos: { x: 10, y: 10, z: 18 },
    volume: Vector3Utils.subtract(
        { x: 757, y: -26, z: 517 },
        { x: 730, y: -57, z: 490 }
    ),
    offset: { x: 0, y: 1, z: 5 },
};

const PKOceanMap: PKMapData = {
    name: "海洋",
    structureName: "你的跑酷我来造:海洋",
    spawnPos: { x: 8, y: 10, z: 8 },
    volume: { x: 17, y: 29, z: 17 },
    offset: { x: 2, y: 4, z: 2 },
};

export const PKMaps = {
    pit: PKPitMap,
    nether: PKNetherMap,
    ocean: PKOceanMap,
} as const;
